<%@page import="swp.vo.Client"%>
<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>修改客户信息页</title>
<script language="javascript">
	function clientUpdate(){
		document.clientUpdateForm.action = "clientservlet?method=clientupdate";
		document.clientUpdateForm.submit();
	}
</script>
</head>
<body>
<%
	Client client = (Client)request.getAttribute("Client"); 
	String clientId = client.getClientId();
	String clientName = client.getClientName();
	String clientPhoneNumber = client.getClientPhoneNumber(); 
	String clientAddress = client.getClientAddress();
	String clientIdCardNumber = client.getClientIdCardNumber();
	String isPay = client.getIsPay();
%>

<form method="post" name="clientUpdateForm">
		<table>
			<tr>	
				<td style="display: none;"><input id="clientId" name="clientId" type="text" value="<%= clientId%>" ></td>
			</tr>
			<tr>	
				<th>姓名</th>
				<td><input id="clientName" name="clientName" type="text" value="<%= clientName%>"></td>
			</tr>
			<tr>	
				<th>电话号码</th>
				<td><input id="clientPhoneNumber" name="clientPhoneNumber" type="text" value="<%= clientPhoneNumber%>"/></td>
			</tr>
			<tr>	
				<th>住址</th>
				<td><input id="clientAddress" name="clientAddress" type="text" value="<%= clientAddress%>"/></td>
			</tr>
			<tr>	
				<th>身份证号码</th>
				<td><input id="clientIdCardNumber" name="clientIdCardNumber" type="text" value="<%= clientIdCardNumber%>"/></td>
			</tr>
			<tr>
				<th>是否缴费</th>
				<td>
						<%
							if(isPay != null && isPay.equals("1")){%>
								<input id="isPay" name="isPay" type="checkbox" value="1" checked="checked"/>
							<%}else{%>
								<input id="isPay" name="isPay" type="checkbox" value="1" />
							<%}
						%>
					</td>
			</tr>
			<tr>
				<th><input id="clientUpdateSubmit" type="submit" onclick="clientUpdate();" value="修改"/></th>
			</tr>
		</table>		
	</form>
</body>
</html>